import math

n=eval(input())
sum=1
ans=1
for i in range(1,n+1):
    ans*=i
    sum+=1/ans
print("%.8f"%sum)